package edu.bu.met683.TravelDroid;


import android.app.Application;
import edu.bu.met683.TravelDroid.data.*;
import edu.bu.met683.TravelDroid.data.DataUtilities.TourState;


public class TravelDroidApplication extends Application 
{

	public TravelDroidApplication()
	{ 
		super();
	}

	@Override
    public void onCreate() {
        super.onCreate();
        this.tourStartDistanceRange = 100;
        currentTourStats = null;
        setTourState(TourState.STOPPED);
    }

    @Override
    public void onTerminate() {
        super.onTerminate();
    }    
	//private properties
    private Tour CurrentTour;
    private int tourStartDistanceRange;
    private Stats currentTourStats;
    private TourState tourState;
    private boolean audioOn = true;

    //public members
	public void SetCurrentTour(Tour tour)
	{
		this.CurrentTour = tour;
	}
	
	public Tour GetCurrentTour()
	{
		return this.CurrentTour;
	}
	public void SetTourStartDistanceRange(int range)
	{
		this.tourStartDistanceRange = range;
	}

	public int GetTourStartDistanceRange() {
		try
		{
			return this.tourStartDistanceRange;
		}
		catch(Exception e)
		{
			return 100;
		}
	}
	
	private PointOfInterest selectedPOI;

	public PointOfInterest getSelectedPOI() 
	{
		return selectedPOI;
	}

	public void setSelectedPOI(PointOfInterest selectedPOI) 
	{
		this.selectedPOI = selectedPOI;
	}

	public Stats getCurrentTourStats() {
		return currentTourStats;
	}

	public void setCurrentTourStats(Stats currentTourStats) {
		this.currentTourStats = currentTourStats;
	}

	public void setTourState(TourState tourState) {
		this.tourState = tourState;
	}

	public TourState getTourState() {
		return tourState;
	}

	public boolean isAudioOn() {
		return audioOn;
	}

	public void setAudioOn(boolean audioOn) {
		this.audioOn = audioOn;
	}

}
